#include "baseInfoWidget.h"

BaseInfoWidget::BaseInfoWidget(QWidget *parent)
    : QWidget{parent}
{
    mainLayout = new QHBoxLayout(this);

    // 左侧屏幕区域
    screenLabel = new QLabel;
    QPixmap screen(":/info/images/android1.png");
    screen.scaled(200,100,Qt::KeepAspectRatio);
    screenLabel->setPixmap(screen);

    // 右侧屏幕区域
    rightLayout = new QGridLayout;
    rightLayout->setSpacing(10);
    // 设备型号
    propLabel = new QLabel("设备型号");
    parp = new QLabel("pass");
    rightLayout->addWidget(propLabel,0,0);
    rightLayout->addWidget(parp, 0,1);
    // 屏幕分辨率
    screenSizeLabel = new QLabel("屏幕分辨率");
    screenSize = new QLabel("Pass");
    rightLayout->addWidget(screenSizeLabel, 1,0);
    rightLayout->addWidget(screenSize,1,1);

    // Android 版本
    androidVersionLabel = new QLabel("安卓版本");
    androidVersion = new QLabel("Pass");
    rightLayout->addWidget(androidVersionLabel, 2,0);
    rightLayout->addWidget(androidVersion,2,1);
    // 内存
    memoryLabel = new QLabel("内存");
    memory = new QLabel("Pass");
    rightLayout->addWidget(memoryLabel, 3,0);
    rightLayout->addWidget(memory,3,1);

    // 序列号
    seqLabel = new QLabel("序列号");
    seqLabel = new QLabel("Pass");
    rightLayout->addWidget(seqLabel, 4,0);
    rightLayout->addWidget(seqLabel,4,1);


    mainLayout->addWidget(screenLabel);
    mainLayout->addLayout(rightLayout);

}
